<div class="sign-1 in-div div-search">
    <form action="<?php echo url('/ad/search') ?>" id='searchForm'>
	<?php if ($isMyPost) { ?>
    	<input type="hidden" name="isMyPost" value="1"/>
	<?php } ?>
        <div>
            <label>Type of Post</label>
            <select name="type">
                <option value="equipment">Equipment</option>
                <option value="supplies" <?php if (isset($_GET['type']) && $_GET['type'] == 'supplies') echo 'selected' ?>>Supplies</option>
                <option value="vendor" <?php if (isset($_GET['type']) && $_GET['type'] == 'vendor') echo 'selected' ?>>Vendor</option>
                <option value="technical" <?php if (isset($_GET['type']) && $_GET['type'] == 'technical') echo 'selected' ?>>Technical Services</option>
                <option value="job" <?php if (isset($_GET['type']) && $_GET['type'] == 'job') echo 'selected' ?>>Jobs Classifies</option>
                <option value="resume" <?php if (isset($_GET['type']) && $_GET['type'] == 'resume') echo 'selected' ?>>Resume</option>
		<?php /*
		  <option value="other" <?php if (isset($_GET['type']) && $_GET['type'] == 'other') echo 'selected' ?>>Other</option>
		 * 
		 */ ?>
            </select>
        </div>
        <div>
            <label>Category</label>
            <select name="category">
                <option value=''>All</option>
		<?php foreach (Category::getList() as $category) : ?>

    		<option value="<?php echo $category->category_id ?>"<?php if (isset($_GET['category']) && $_GET['category'] == $category->category_id) echo ' selected' ?>>
			<?php echo h($category->name) ?>
    		</option>

		<?php endforeach; ?>

            </select>
        </div>
	<?php /*
	  <div>
	  <label> Manufacturer:</label>
	  <select>
	  <option> - Select - </option>
	  </select>
	  </div>
	 * 
	 */ ?>
        <div>
            <label>Country</label>
	    <?php
	    //echo CHtml::dropDownList('country', 'US', Country::getSelectList())
	    if (isset($_GET['country'])) {
		echo CHtml::dropDownList('country', $_GET['country'], Country::getSelectList());
	    } else {
		echo CHtml::dropDownList('country', '', Country::getSelectList());
	    }
	    ?>
        </div>
        <div>
            <label>State</label>
	    <input type="text" name="state-search" value="<?php if (isset($_GET['state-search'])) echo $_GET['state-search']; ?>"/>
	    <?php
	    /*
	      <select>
	      <option> Select State</option>
	      </select>
	     */
	    ?>

        </div>

        <div style="clear:both;">
            <input type="submit" value="Search" class="btn btn-warning btn-large">
        </div>
    </form>
</div>